<template>
  <section style="width: 100%">
    <div v-if="widget.code === 'null-space'">
      <null-space :widget="widget" :showConfDialog="showConfDialog"></null-space>
    </div>
    <div v-else-if="widget.code === 'examine-time'">
      {{widget.title}}
    </div>
    <div v-else-if="widget.code === 'report-sn'">
      {{widget.title}}
    </div>
    <div v-else-if="widget.code === 'user-info'">
      <show-user-info :widget="widget" :showConfDialog="showConfDialog"></show-user-info>
    </div>
    <div v-else-if="widget.code === 'score-grade'" style="width: 100%">
      <score-grade :widget="widget" :mockData="mockData"  id="score"></score-grade>
    </div>
    <div v-else-if="widget.code === 'tizhi-a'">
      {{widget.title}}
    </div>
    <div v-else-if="widget.code === 'tizhi-b'">
      {{widget.title}}
    </div>
    <div v-else-if="widget.code === 'tizhi-c'">
      {{widget.title}}
    </div>
    <div v-else-if="widget.code === 'tizhi-d'">
      {{widget.title}}
    </div>
    <div v-else-if="widget.code === 'tizhi-e'">
      {{widget.title}}
    </div>
    <div v-else-if="widget.code === 'fangan-a'">
      {{widget.title}}
    </div>
    <div v-else-if="widget.code === 'fangan-b'">
      {{widget.title}}
    </div>
    <div v-else-if="widget.code === 'fangan-c'">
      {{widget.title}}
    </div>
    <div v-else-if="widget.code === 'fangan-d'">
      {{widget.title}}
    </div>
    <div v-else-if="widget.code === 'fangan-e'">
      {{widget.title}}
    </div>
    <div v-else-if="widget.code === 'fangan-f'">
      {{widget.title}}
    </div>
    <div v-else-if="widget.code === 'fangan-g'">
      {{widget.title}}
    </div>
    <div v-else-if="widget.code === 'fangan-h'">
      {{widget.title}}
    </div>
    <div v-else-if="widget.code === 'fangan-i'">
      {{widget.title}}
    </div>
    <div v-else-if="widget.code === 'report-intro'">
      {{widget.title}}
    </div>
    <div v-else-if="widget.code === 'jk-record'">
      {{widget.title}}
    </div>
  </section>
</template>

<script>
  import scoreGrade from './score-grade'
  import nullSpace from './null-space'
  import showUserInfo from './user-info'
  export default {
    name: "index",
    props:['widget','mockData'],
    components:{nullSpace,showUserInfo,scoreGrade},
    data() {
      return {
        showConfDialog: false,
      }
    },
    created(){
      console.log('看下是什么-----',this.widget)
    }
  }
</script>

<style scoped>

</style>
